/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.aptech.search;

import com.aptech.entity.HouseType;
import com.aptech.session.HouseTypeFacadeLocal;
import java.util.List;
import javax.ejb.EJB;
import javax.faces.bean.ManagedBean;
import javax.faces.bean.RequestScoped;

/**
 *
 * @author Administrator
 */
@ManagedBean
@RequestScoped
public class SearchHouseTypeBean {
    @EJB
    private HouseTypeFacadeLocal houseTypeFacade;
    private String field;
    private Object value;

    public String getField() {
        return field;
    }

    public void setField(String field) {
        this.field = field;
    }

    public List<HouseType> getListhousetype() {
        return listhousetype;
    }

    public void setListhousetype(List<HouseType> listhousetype) {
        this.listhousetype = listhousetype;
    }

    public Object getValue() {
        return value;
    }

    public void setValue(Object value) {
        this.value = value;
    }
    private List<HouseType> listhousetype;
    /** Creates a new instance of SearchHouseTypeBean */
    public SearchHouseTypeBean() {
    }
    
    public String searchhousetype()
    {
        listhousetype=houseTypeFacade.SearchHouseType(field, value);
        return "ResultHouseType";
    }
}
